package edu.ucsc.gameAI.hfsm;

import java.util.ArrayList;
import java.util.Collection;

import edu.ucsc.gameAI.IAction;

public class Result implements IResult {

	Collection<IAction> actions;
	IHTransition transition;
	int level;

	public Result() {
		actions = new ArrayList<IAction>();
	}

	@Override
	public Collection<IAction> getActions() {
		return actions;
	}

	@Override
	public void setActions(Collection<IAction> actions) {
		this.actions = actions;
	}

	@Override
	public void addAction(IAction action) {
		if (action != null)
			this.actions.add(action);
	}

	@Override
	public void addActions(Collection<IAction> actions) {
		this.actions.addAll(actions);
	}

	@Override
	public IHTransition getTransition() {
		return transition;
	}

	@Override
	public void setTransition(IHTransition transition) {
		if (transition != null)
			this.transition = transition;
	}

	@Override
	public int getLevel() {
		return level;
	}

	@Override
	public void setLevel(int level) {
		this.level = level;
	}

}
